package com.woniuxy.microstockserver.service.impl;

import com.woniuxy.microstockserver.bean.AllocationGoodsDetailsBean;
import com.woniuxy.microstockserver.mapper.AllocationGoodsDetailsMapper;
import com.woniuxy.microstockserver.service.IAllocationGoodsDetailsService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author 赵雄伟
 * 调拨单impl
 */
@Service
public class AllocationGoodsDetailsServiceImpl implements IAllocationGoodsDetailsService {
    @Resource
    private AllocationGoodsDetailsMapper allocationGoodsDetailsMapper;
    @Override
    public void saveAllocationGoodsDetailsBean(Long alloId, List<AllocationGoodsDetailsBean> allocationGoodsDetailsBeans) {
        allocationGoodsDetailsMapper.saveAllocationGoodsDetailsBean(alloId,allocationGoodsDetailsBeans);
    }

    @Override
    public List<AllocationGoodsDetailsBean> findAllocationAndGoodsDetail(Long id) {
        return allocationGoodsDetailsMapper.findAllocationAndGoodsDetail(id);
    }

    @Override
    public void deleteByAlloId(Long id) {
        allocationGoodsDetailsMapper.deleteByAlloId(id);
    }
}
